export const state = () => {
  return {
    money: "0",  //当前充值资金数额
    currency_code: "",  //CNY, USD, HKD, JPY, CAD, KHR
    account_code: "CNY",
    changeMoney: "20",
    paymentChoose: "现金",  //选择付款方式
    isShowTips: true,   //是否显示充值汇率提示
    wealthRechargeStep: "step1" //step1, step2, step3, step4
  }
}

export const mutations = {
  SET_WEALTH_RECHARGE_MONEY (state, money) {
    state.money = money;
  },
  SET_CURRENCY_CODE (state, code) {
    state.currency_code = code;
  },
  SET_ACCOUNT_CODE (state, code) {
    state.account_code = code;
  },
  SET_WEALTH_RECHARGE_MONEY_CHANGE (state, changeMoney) {
    state.changeMoney = changeMoney;
  },
  SET_WEALTH_RECHARGE_PAYMENT_CHOOSE (state, paymentChoose) {
    state.paymentChoose = paymentChoose;
  },
  SET_WEALTH_RECHARGE_MONEY_TIPS_SHOW (state, bool) {
    state.isShowTips = bool;
  },
  SET_WEALTH_RECHARGE_STEP (state, step) {
    state.wealthRechargeStep = step;
  }
}

export const getters = {

}

export const actions = {
  // async GET_AREA_CODE ({ commit }){
  //   try {
  //     let data = await this.$axios.get('/area_code.json');
  //     console.log(data);
  //   } catch (e) {
  //     throw e;
  //   }
  // }
}
